<template>
  <view @click="isShow=false" class="root" v-show="isShow">
    <view class="mask">
      <view class="msg">{{msg}}</view>
    </view>
  </view>
</template>
<script>
export default {
  props:{
    msg : ''    
  },
  data (){
    return {
      isShow:false,
      show(){
        this.isShow = true
      },
      hide(){
        this.isShow = false
      }
    }
  }
}
</script>
<style scoped>
.root {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
}
.mask {
  display: flex;
  justify-content: center;
  align-items: center;
  height: 100vh;
  width: 100vw;
  background-color: rgba(0,0,0,.3);
}
.msg {
  background-color: rgba(0,0,0,.8);
  color: #fff;
  min-width: 50vw;
  min-height: 10vh;
  display: flex;
  justify-content: center;
  align-items: center;
  box-shadow: 0 0 10rpx 5rpx #fff;
}
</style>